package com.flyduck.system.vo.config;

import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.Data;

import javax.validation.constraints.NotBlank;
import javax.validation.constraints.Pattern;
import java.io.Serializable;

/**
 * @program: flyduck-platform
 * @description: 系统:参数更新请求VO
 * @author: flyduck
 * @create: 2021-03-25 20:27
 **/
@Data
@ApiModel(value = "系统:参数更新请求VO")
public class SysConfigUpdateReqVO implements Serializable {

    @NotBlank(message = "ID不能为空")
    @ApiModelProperty(value = "ID",required = true)
    private String id;

    @NotBlank(message = "参数名称不能为空")
    @ApiModelProperty(value = "参数名称",required = true)
    private String configName;

    @NotBlank(message = "参数键名不能为空")
    @ApiModelProperty(value = "参数键名",required = true)
    private String configKey;

    @NotBlank(message = "参数值不能为空")
    @ApiModelProperty(value = "参数值",required = true)
    private String configValue;

    @NotBlank(message = "参数类型不能为空")
    @Pattern(regexp = "[/^1$|^2&/]*", message = "参数类型为：1系统参数 2应用参数")
    @ApiModelProperty(value = "参数类型",required = true)
    private String configType;

    @NotBlank(message = "状态不能为空")
    @Pattern(regexp = "[/^1$|^2&/]*", message = "状态为：1启用 2禁用")
    @ApiModelProperty(value = "状态",required = true)
    private String status;
}
